﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ZetaPrints.ZetaClient.Shared
{
    /// <summary>
    /// EventMessenger is a little class that will 
    /// go up to communication information between
    /// the classes and communicate with the 
    /// prensentation layer
    /// </summary>
    public class EventMessenger:EventArgs
    {
        #region public properties
        /// <summary>
        /// The date time that this entry was created
        /// </summary>
        public DateTime DateTimeEntry { get; set; }
        /// <summary>
        /// The type of messege this is
        /// </summary>
        public MessageTypeOption MessageType { get; set; }
        /// <summary>
        /// The body of the message
        /// </summary>
        public string MessageString { get; set; }
        /// <summary>
        /// Message object when the entry is set right
        /// </summary>
        public object MessageObject { get; set; }
        #endregion


        #region constructors
        /// <summary>
        /// Initialzie the object to send text messages with commands
        /// </summary>
        /// <param name="messageType"></param>
        /// <param name="message"></param>
        public EventMessenger(MessageTypeOption messageType, string message)
        {
            DateTimeEntry = DateTime.Now;
            MessageType = messageType;
            MessageString = message;
            MessageObject = null;
        }
        /// <summary>
        /// Initialzie the class with a object carrier
        /// </summary>
        /// <param name="messageObject"></param>
        /// <param name="message"></param>
        public EventMessenger(MessageTypeOption messageType, object messageObject)
        {
            DateTimeEntry = DateTime.Now;
            MessageType = messageType;
            MessageString = string.Empty;
            MessageObject = messageObject;
        }
        #endregion
    }
}
